home *** CD-ROM | disk | FTP | other *** search
/ Celestin Apprentice 2 / Apprentice-Release2.iso / Tools / MPW / gzip 1.2.2 / msdos / Makefile.msc < prev    next >
Encoding:
Makefile  |  1993-06-22  |  2.8 KB  |  117 lines  |  [TEXT/MPS ]

  1. # Makefile for gzip
  2. # Microsoft C 5.1 or 6.0.
  3.  
  4. # To use, do "make makefile.msc"
  5.  
  6. # WARNING: the small model is not supported. The compact model is used
  7. # here. If you want to use the large model, add -D__LARGE__ to ASFLAGS
  8. # Add -DSMALL_MEM to CFLAGS if you wish to reduce the memory
  9. # requirements. Add -DNO_ASM to CFLAGS and remove match.obj from OBJI if
  10. # you do not have masm.
  11.  
  12. # ------------- Microsoft C 5.1 and later -------------
  13. MODEL=-AC
  14. FP=
  15. CFLAGS=-Ox -nologo $(MODEL)
  16. BFLAGS=-Oait -Gs -nologo $(MODEL)
  17. # BFLAGS are the 'bug workaround' flags.
  18. CC=cl
  19. LD=link
  20. LDFLAGS=/e/st:0x1000/noe
  21. #     If you use lzexe as recommended, remove /e from LDFLAGS
  22. AS=masm
  23. #     For MSC 6.0, use: AS=ml 
  24. ASFLAGS=-ml -t
  25. # Add -DDYN_ALLOC to ASFLAGS if you have defined it in tailor.h or CFLAGS
  26. LIB = c:\c51\lib
  27.  
  28. # ------------- Common declarations:
  29. STRIP=rem
  30. #    If you don't have lzexe, get it (by ftp on wuarchive.wustl.edu
  31. #    in /mirrors/msdos/filutl/lzexe91e.zip). Then define:
  32. #STRIP=lzexe
  33. #    Or if you've registered PKLITE, then define:
  34. #STRIP=pklite
  35. #    This makes a big difference in .exe size (and possibly load time)
  36.  
  37. O=.obj
  38. OBJA=match$(O) $(LIB)\setargv$(O)
  39. ALLOCA=alloca$(O)
  40.  
  41. # ------------- Used by install rule
  42. # set BIN to the directory you want to install the executables to
  43. BIN = c:\bin
  44.  
  45. # variables
  46. OBJ1 = gzip$(O) zip$(O) deflate$(O) trees$(O) bits$(O) unzip$(O) inflate$(O) \
  47.        util$(O)
  48. OBJ2 = crypt$(O) lzw$(O) unlzw$(O) unpack$(O) unlzh$(O) getopt$(O) $(OBJA) \
  49.        $(ALLOCA)
  50.  
  51. gzip.obj: gzip.c gzip.h tailor.h crypt.h revision.h lzw.h
  52.     $(CC) -c $(CFLAGS) $*.c
  53.  
  54. zip.obj: zip.c gzip.h tailor.h crypt.h
  55.     $(CC) -c $(CFLAGS) $*.c
  56.  
  57. deflate.obj: deflate.c gzip.h tailor.h
  58.     $(CC) -c $(CFLAGS) $*.c
  59.  
  60. trees.obj: trees.c gzip.h tailor.h
  61.     $(CC) -c $(CFLAGS) $*.c
  62.  
  63. bits.obj: bits.c gzip.h tailor.h crypt.h
  64.     $(CC) -c $(CFLAGS) $*.c
  65.  
  66. unzip.obj: unzip.c gzip.h tailor.h crypt.h
  67.     $(CC) -c $(CFLAGS) $*.c
  68.  
  69. inflate.obj: inflate.c gzip.h tailor.h
  70.     $(CC) -c $(CFLAGS) $*.c
  71.  
  72. util.obj: util.c gzip.h tailor.h crypt.h
  73.     $(CC) -c $(BFLAGS) $*.c
  74.  
  75. crypt.obj: crypt.c gzip.h tailor.h crypt.h
  76.     $(CC) -c $(CFLAGS) $*.c
  77.  
  78. lzw.obj: lzw.c gzip.h tailor.h
  79.     $(CC) -c $(CFLAGS) $*.c
  80.  
  81. unlzw.obj: unlzw.c gzip.h tailor.h lzw.h
  82.     $(CC) -c $(CFLAGS) $*.c
  83.  
  84. unpack.obj: unpack.c gzip.h tailor.h
  85.     $(CC) -c $(CFLAGS) $*.c
  86.  
  87. unlzh.obj: unlzh.c gzip.h tailor.h
  88.     $(CC) -c $(CFLAGS) $*.c
  89.  
  90. tailor.obj: tailor.c gzip.h tailor.h
  91.     $(CC) -c $(CFLAGS) $*.c
  92.  
  93. getopt.obj: getopt.c getopt.h
  94.     $(CC) -c $(CFLAGS) $*.c
  95.  
  96. alloca.obj: alloca.c
  97.      $(CC) -c $(CFLAGS) $*.c
  98.  
  99. match.obj:    match.asm
  100.     $(AS) $(ASFLAGS) match;
  101.  
  102. # we must cut the command line to fit in the MS/DOS 128 byte limit:
  103. gzip.exe: $(OBJ1) $(OBJ2)
  104.     echo $(OBJ1)+ > gzip.rsp
  105.     echo $(OBJ2); >> gzip.rsp
  106.     $(LD) $(LDFLAGS) @gzip.rsp
  107.     del gzip.rsp
  108.     $(STRIP) gzip.exe
  109.  
  110. install: gzip.exe
  111.     copy /b gzip.exe $(BIN)
  112.     copy /b gzip.exe $(BIN)\gunzip.exe
  113.  
  114. #clean:
  115. #    del *.obj
  116. #    del *.exe
  117.